package info.wangyuan.agent.common.Constant;

import java.io.File;
import java.nio.file.FileSystems;
import java.nio.file.PathMatcher;
import java.util.Set;

/**
 * 文件相关常量
 *
 * @author Albert
 * @since 2025-07-20 16:52:08
 */
public class FileConstant {
    public static final String RAG_ROOT_PATH = System.getProperty("user.dir") + File.separator + "files";
    public static final String STATIC_ROOT_PATH = System.getProperty("user.dir") + File.separator + "static";
    public static final String LOG_ROOT_PATH = System.getProperty("user.dir") + File.separator + "logs";

    // B => KB => MB
    public static final long MAX_FILE_SIZE = 1024 * 1024 * 50;

    public static final Set<String> PATH_MATCHER_EXTENSIONS = Set.of("txt", "pdf", "doc", "docx");

    public static final PathMatcher PATH_MATCHER = FileSystems.getDefault().getPathMatcher("glob:**.{txt,pdf,doc,docx}");

}
